﻿// See https://aka.ms/new-console-template for more information


Console.WriteLine("Main thread started...");

Thread thread = new Thread(() =>
{
	Console.WriteLine("My foreground thread started...");
	Thread.Sleep(1000);
	Console.WriteLine("My foreground thread stopping...");
});

thread.IsBackground = false;
thread.Start();

Thread.Sleep(500);
Console.WriteLine("Main thread stopping...");